 function   rtrim(s)
  {
          var   l;
          var   ret;

          l   =   s.length;
          while(s.charAt(l   -   1)   ==   " ")
              l--;
          ret =  s.substring(0,l);
          return   ret;
  }

  function   ltrim(s)
  {
  var   l;
  var   ret;

  l   =   0;
  while(s.charAt(l)   ==   " ")
  l++;
  ret   =   s.substring(l);
  return   ret;
  }

  function   trim(s)
  {
  return   ltrim(rtrim(s));
  }

  function checkIfTab(s)
  {
  	for(var i=0; i<s.length; ++i)
  	{
  		if((s[i] == "	") || (s[i] == " "))
  		{
  			return false;
  		}
  	}
  	return true;
  }

function deleteCookie(name)
{
  document.cookie = name+"=;expires="+(new Date(0)).toGMTString();
}